<%@ page language="java" contentType="text/html; charset=UTF-8"
	pageEncoding="UTF-8"%>
	<%@ taglib prefix="core" uri="http://java.sun.com/jsp/jstl/core" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<script type="text/javascript">
	$(document).ready(function(){
		$("#modify").click(function(){
			location.href="/${initParam.context_root}/modifyAuctionForm.do?auctionNo=${requestScope.auction.auctionNo}";
		});
		$("#delete").click(function(){
			location.href="/${initParam.context_root}/deleteAuction.do?auctionNo=${requestScope.auction.auctionNo}";
		});
	});
</script>
<div style="width: 90%; float: left;" align="center">
	<div style="width: 100%; float: left;">
		<table align="left" width="100%">
			<tr>
				<td>제목</td>
				<td><b>${requestScope.auction.auctionName }</b></td>
				<td>거래상태</td>
				<td></td>
			</tr>
			<tr>
				<td>작성일</td>
				<td>${requestScope.auction.registerDate }</td>
				<td>조회</td>
				<td></td>
			</tr>
		</table>
	</div>
	<div style="width: 100%; float: left;">
		<hr noshade="noshade">
		<center><p>판매자 정보</p></center>
		<hr noshade="noshade">
	</div>

	<div style="width: 100%; float: left;">
		<table align="left" width="100%">
			<tr>
				<td>판매자</td>
				<td>${requestScope.auction.memberDTO.id }</td>
			</tr>
			<tr>
				<td>이메일</td>
				<td>${requestScope.auction.memberDTO.email}</td>
			</tr>
			<tr>
				<td>휴대폰 번호</td>
				<td>${requestScope.auction.memberDTO.phone}</td>
			</tr>
		</table>
	</div>
	<div style="width: 100%; float: left;">
	<hr noshade="noshade">
		<center><p>판매 쿠폰 정보</p></center>
		<hr noshade="noshade">
	</div>
	<div style="width: 100%; float: left;">
		<table align="left" width="100%">
			<tr>
				<td>상품명</td>
				<td>${requestScope.auction.productName }</td>
			</tr>
			<tr>
				<td>판매사이트</td>
				<td>XXX</td>
			</tr>
			<tr>
				<td>상품URL</td>
				<td>${requestScope.auction.sellSite}</td>
			</tr>
			<tr>
				<td>상품이미지</td>
				<td><img
					src="/${initParam.context_root }/upfile/${requestScope.auction.file }"></td>
			</tr>
			<tr>
				<td>정상가</td>
				<td>${requestScope.auction.originalPrice }</td>
			</tr>
			<tr>
				<td>쿠폰가</td>
				<td>${requestScope.auction.couponPrice }</td>
			</tr>
			<tr>
				<td>희망가</td>
				<td>${requestScope.auction.wantPrice }</td>
			</tr>
			<tr>
				<td>판매수량</td>
				<td>${requestScope.auction.quantity}</td>
			</tr>
			<tr>
				<td>쿠폰 사용기간</td>
				<td>${requestScope.auction.useStartDate} ~
					${requestScope.auction.useEndDate}</td>
			</tr>
			<tr>
				<td>지역</td>
				<td>${requestScope.auction.saleLocation}</td>
			</tr>
			<tr>
				<td>카테고리</td>
				<td>${requestScope.auction.categoryName}</td>
			</tr>
			<tr>
				<td>상세설명</td>
				<td>${requestScope.auction.auctionContent}</td>
			</tr>
		</table>
	</div>
<div align="center" style="width: 90%;">
	<core:if test="${not empty sessionScope.memberDTO and sessionScope.memberDTO.id eq requestScope.auction.memberDTO.id}">
	<input type="button" value="수정" id="modify"> <input type="button" value="삭제" id="delete">	
	</core:if>
</div>
</div>
